<?PHP
class HTMLResult extends BaseResult
{
  private $templateName;

  public function __construct($templateName, $context)
  {
	 parent::__construct($context);
	 
	 $this->templateName = $templateName;
  }

  public function show()
  {
	 $cont = array($this->getContext());
	 array_walk_recursive($cont, function(&$property, $key){
		if (method_exists($property, "exportVars"))
		{
		   $property = $property->exportVars();
		}
	 });

	 Template::show($this->templateName, $cont[0]);
  }
}